package edu.asu.sapa.ground.update;

import edu.asu.sapa.Planner;
import edu.asu.sapa.ground.State;

public class RestIntervalLoader extends Load {

	@Override
	public final boolean load(State s, Context c) {
		float t = c.start;
		float f = c.finish;
		for (Update u : contents) {
			s.events.add(c,u,UpdateWrapper.StartAfter,t);
			s.events.add(c,u,UpdateWrapper.FinishAfter,f);
		}
		return true;
	}
	
	public final boolean applicable(State s, Context c) {
		return true;
	}
	
	public String toString() {
		return "\t(over all " + super.toString();
	}

}
